package com.synergy.stockflow.production.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import java.math.BigDecimal;
import java.util.Date;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Schema
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "production_report_detail")
public class ProductionReportDetail {
    /**
     * 报工明细ID
     */
    @TableId(value = "detail_id", type = IdType.ASSIGN_ID)
    @Schema(description="报工明细ID")
    private String detailId;

    /**
     * 报工ID
     */
    @TableField(value = "report_id")
    @Schema(description="报工ID")
    private String reportId;

    /**
     * 工序ID
     */
    @TableField(value = "process_id")
    @Schema(description="工序ID")
    private String processId;

    /**
     * 物料ID
     */
    @TableField(value = "product_id")
    @Schema(description="物料ID")
    private String productId;

    /**
     * 计划数量
     */
    @TableField(value = "planned_quantity")
    @Schema(description="计划数量")
    private BigDecimal plannedQuantity;

    /**
     * 报工数量
     */
    @TableField(value = "reported_quantity")
    @Schema(description="报工数量")
    private BigDecimal reportedQuantity;

    /**
     * 合格数量
     */
    @TableField(value = "qualified_quantity")
    @Schema(description="合格数量")
    private BigDecimal qualifiedQuantity;

    /**
     * 不合格数量
     */
    @TableField(value = "defect_quantity")
    @Schema(description="不合格数量")
    private BigDecimal defectQuantity;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @TableField(value = "create_time")
    @Schema(description="创建时间")
    private Date createTime;
}